import React, { Component } from 'react'
import { Table, Tag } from 'antd'
import { asyncTable } from '../high/table'
import columns from './columns'

class MyTable extends Component {
    render() {
        const { list } = this.props
        return (
            <div>
                <Table columns={columns} dataSource={ list } />
            </div>
        )
    }
}

const UserTable = asyncTable(MyTable)("/api/getUser")
const StateTable = asyncTable(MyTable)("/api/getState")
MyTable = asyncTable(MyTable)("/api/getList")

export  {
    MyTable,
    UserTable,
    StateTable
}
